
package com.hlkj.pay.gateway.order;
/*
 * Hlpay-Plus aggregate payment system.
 * Copyright (c) 2024-2025 Hlpay Team Copyright has the right of final interpretation.
 */

import com.hlkj.framework.common.pojo.CommonResult;
import com.hlkj.pay.dto.order.NotifyOrderWithdrawDto;
import com.hlkj.pay.infrastructure.model.merchant.MerchantAppChannelDO;
import com.hlkj.pay.infrastructure.model.order.OrderWithdrawDO;
import com.hlkj.pay.infrastructure.model.pay.ProviderChannelConfigDO;

import javax.servlet.http.HttpServletRequest;

/**
 * @author HlpayTeam
 * @date 2024/11/06 13:28
 */
public interface IChannelWithdrawGateway {
    /**
     *
     * @param channelCode
     * @return
     */
    boolean extensionExist(String channelCode);

    /**
     *
     * @param orderWithdrawDO
     * @return
     */
    OrderWithdrawDO queryChannelOrder(OrderWithdrawDO orderWithdrawDO);

    /**
     *
     * @param request
     * @param providerChannelConfigDO
     * @return
     */
    CommonResult<NotifyOrderWithdrawDto> orderStatusParse(HttpServletRequest request, ProviderChannelConfigDO providerChannelConfigDO);

    /**
     *
     * @param merchantAppChannelDO
     * @param orderTransfer
     * @return
     */
    CommonResult<OrderWithdrawDO> submitWithdrawOrder(MerchantAppChannelDO merchantAppChannelDO, OrderWithdrawDO orderTransfer);
}
